<?php
/**
 * @var \yii\web\View $this
 * @var $searchModel \workin\modules\increment\models\MortgageSignupHuirongSearch
 * $dataProvider yii\data\ActiveDataProvider
 */
use yii\helpers\Html;
use kartik\grid\GridView;
$this->title = "抵押登记列表";
$this->params['breadcrumbs'][] = \yii\helpers\Html::a('惠瀜业务', ['index']);
$this->params['breadcrumbs'][] = $this->title;
?>
<div class="ms-back-result-list">
    <h3><?= Html::encode($this->title) ?></h3>
    <?= GridView::widget([
        'dataProvider' => $dataProvider,
        'filterModel' => $searchModel,
        'columns' => [
//            ['class' => 'kartik\grid\SerialColumn'],

//            'id',
            'search_index',
            [
                'class' => \kartik\grid\ExpandRowColumn::className(),
                'width' => '50px',
                'value' => function ($model, $key, $index, $column) {
                    if ($model->mortgageSignupHuirongBack){
                        return \kartik\grid\GridView::ROW_COLLAPSED;
                    }else{
                        return "没有回调";
                    }
                },
                'detail' => function ($model, $key, $index, $column) {
                    return Yii::$app->controller->renderPartial('ms-back-result.php', ['model'=>$model, 'id'=>$key]);
                },
                'headerOptions' => ['class' => 'kartik-sheet-style'],
                'expandOneOnly' => true,
//                'pageSummary'=>'总计',//可以是字符串，当为true时，自动合计
            ],
            'mortgageSignupHuirongBack.report_id',
            'business_code',
            'plate_number',
//            'pic',
//            'pic_net_path',
//            'pic_type',
            'call_back',
            'grant_key',
            'api_key',

//            ['class' => 'kartik\grid\ActionColumn'],
            'order_report_id',
        ],
    ]); ?>
</div>
